package com.cdks.wuxiu.common.component.constant;

/**
 * Redis Key 枚举类
 */
public enum RedisKeyEnum {
    /**
     * ADMIN AUTH JWT ACCESS 格式
     * admin:auth:jwt:access:{username}:{jwt}
     */
    ADMIN_AUTH_JWT_ACCESS_FORMAT("admin:auth:jwt:access:{}:{}"),
    /**
     * ADMIN AUTH JWT ACCESS 前缀
     */
    ADMIN_AUTH_JWT_ACCESS_PREFIX("admin:auth:jwt:access:"),
    /**
     * ADMIN AUTH JWT REFRESH 格式
     * admin:auth:jwt:refresh:{username}:{jwt}
     */
    ADMIN_AUTH_JWT_REFRESH_FORMAT("admin:auth:jwt:refresh:{}:{}"),
    /**
     * ADMIN AUTH JWT REFRESH 前缀
     */
    ADMIN_AUTH_JWT_REFRESH_PREFIX("admin:auth:jwt:refresh:"),
    /**
     * ADMIN AUTH CACHE 前缀
     */
    ADMIN_AUTH_CACHE_PREFIX("admin:auth:cache:"),

    /**
     * ADMIN AUTH ROLE 前缀
     */
    ADMIN_AUTH_ROLE_PREFIX("admin:auth:role:"),

    /**
     * ADMIN AUTH PERMISSION 前缀
     */
    ADMIN_AUTH_PERMISSION_PREFIX("admin:auth:permission:"),

    /**
     * ADMIN AUTH CAPTCHA 前缀
     */
    ADMIN_AUTH_CAPTCHA_PREFIX("admin:auth:captcha:"),
    ;

    private final String key;

    RedisKeyEnum(String key) {
        this.key = key;
    }

    public String getKey() {
        return key;
    }
}
